<button class="btn btn-outline-primary" (click) = "save()">保存</button>
<button class="btn btn-outline-warning" (click)="goBack()">返回</button>

<div class="form-group">
  <label for="exampleInputEmail1">标题</label>
  <input type="email" class="form-control" id="exampleInputEmail1" aria-describedby="emailHelp" placeholder="请输入标题" [(ngModel)]="singlepage.title">
  <small id="emailHelp" class="form-text text-muted">标题不超过40个字，不要包含特殊字符</small>
</div>

<div class="form-group">
  <label for="exampleInputEmail1">内容</label>
  <input type="email" class="form-control" id="exampleInputEmail1" aria-describedby="emailHelp" placeholder="请输入内容" [(ngModel)]="singlepage.summary">
  <small id="emailHelp" class="form-text text-muted">内容不超过40个字，不要包含特殊字符</small>
</div>

<div class="form-group">
  <label for="exampleInputEmail1">图片</label>
  <input type="email" class="form-control" id="exampleInputEmail1" aria-describedby="emailHelp" placeholder="请输入图片路径" [(ngModel)]="singlepage.img">

  <input type="file" (change)="onFileChanged($event)">
  <button (click)="onUpload()">上传</button>

</div>

<div class="form-group">
  <label for="exampleInputEmail1">详细内容</label>
  <input type="email" class="form-control" id="exampleInputEmail1" aria-describedby="emailHelp" placeholder="请输入详细内容" [(ngModel)]="singlepage.detail">
  <small id="emailHelp" class="form-text text-muted">详细内容不超过40个字，不要包含特殊字符</small>
</div>